from amplitude.controller import Controller
import os, subprocess

class UpdateWC(Controller): 
    actions = ['update']
    
    def update(c, req):
        """update the given working copy path"""
        if c.config.Repository is not None and c.config.Repository.path is not None:
            wcpath = os.path.join(c.config.Repository.path, req.params.path or '')
            subprocess.call(['svn', 'update', wcpath])
            